package com.atguigu.lease.web.app.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.atguigu.lease.model.entity.FacilityInfo;
import com.atguigu.lease.web.app.service.FacilityInfoService;
import com.atguigu.lease.web.app.mapper.FacilityInfoMapper;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author liubo
* @description 针对表【facility_info(配套信息表)】的数据库操作Service实现
* @createDate 2023-07-26 11:12:39
*/
@Service
public class FacilityInfoServiceImpl extends ServiceImpl<FacilityInfoMapper, FacilityInfo>
    implements FacilityInfoService{

    /**
     * 获取房间的配套信息列表
     *
     * @param id 房间id
     * @return 配套信息列表
     */
    @Override
    public List<FacilityInfo> getFacilityInfoListByRoomId(Long id) {
        return baseMapper.selectFacilityInfoListByRoomId(id);
    }

    /**
     * 获取公寓配套列表
     *
     * @param id 公寓id
     * @return 配套信息列表
     */
    @Override
    public List<FacilityInfo> getFacilityInfoListByApartmentId(Long id) {
        return baseMapper.selectFacilityInfoListByApartmentId(id);
    }
}




